package com.kly.user.serviceImpl;

import com.kly.user.UserService;
import com.kly.user.db.dao.UserTestDao;
import com.kly.user.db.entity.UserTestEntity;
import org.apache.dubbo.config.annotation.DubboService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
@DubboService
public class UserServiceImpl implements UserService {

    @Autowired
    private UserTestDao userTestDao;

    @Override
    public String queryUserById(Long userId) {
        UserTestEntity userTestEntity = userTestDao.selectByPrimaryKey(userId);
        return userTestEntity == null ? null : userTestEntity.getName();
    }
}
